package cn.fscode.code.generator.gen;

import lombok.Getter;
import lombok.Setter;

import java.util.Collections;
import java.util.List;

/**
 * 数据库表定义,从这里可以获取表名,字段信息
 */
@Getter
@Setter
public class TableDefinition {
    /**
     * PSSQL对应的schema
     */
    private String schema;

    /**
     * 表名
     */
    private String tableName;

    /**
     * 表注释
     */
    private String comment;

    private List<TableIndexDefinition> tableIndexDefinitions = Collections.emptyList();

    /** 相关字段 */
    private List<ColumnDefinition> columnDefinitions = Collections.emptyList();

    public TableDefinition() {
    }

    public TableDefinition(String tableName) {
        this.tableName = tableName;
    }
}
